<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html lang="en">

<%--
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Java实训团队协作简单案例 - 用户登录</title>
    <link rel="shortcut icon" href="assets/img/favicon.ico" type="image/x-icon"/>
    <link rel="stylesheet" href="assets/vendors/font-awesome-4.7.0/css/font-awesome.min.css"/>
    <link rel="stylesheet" href="assets/css/core.css"/>

    <link rel="stylesheet" href="assets/css/login.css"/>
</head>

<body>
<h1>用户登录</h1>
<form class="login-container" action="/login">

    <div class="login-item">
        <label for="username">登录账号：</label>
        <input name="u" type="text" id="username"/>
    </div>
    <div class="login-item">
        <label for="password">登录密码：</label>
        <input name="p" type="password" id="password"/>
    </div>
    <div class="login-item">
        <label>验证码：</label>
        <input name="c" type="text" class="login-code"/>
        <img src="/code" id="ccc"/>
        <a href="javascript:void(0)" onclick="changCode()">看不清?</a>
    </div>
    <div class="login-item">
        <button type="submit">登录</button>
    </div>
</form>
</body>

<script>
    function changCode() {
        ccc.src = "/code?t=" + Math.random();
    }
</script>

</html>
--%>


<head>
    <meta charset="UTF-8">
    <title>Java实训团队协作简单案例 - 用户登录</title>
    <link rel="stylesheet" href="assets/css/login.css" />
</head>

<body bgcolor="#F2F2F2">
    <form class="login-container" action="/login">
        <h1>用户登录</h1>
        <div class="login-item">
            <label>登录账号：</label>
            <input name="u" type="text"/>
        </div>
        <div class="login-item">
            <label>登录密码：</label>
            <input name="p" type="password"/>
        </div>
        <div class="login-item">
            <label>验证码：</label>
            <input name="c" type="text" class="login-code"/>
            <img src="/code" id="ccc"/>
            <a  href="javascript:void(0)" onclick="changCode()" style="font-size: 3px">换一张</a>
        </div>
        <%--提交表单信息的按钮--%>
        <div class="login-item">
            <button type="submit">登录</button>
            <button type="reset">清空</button>
        </div>
    </form>


</body>

<script>
    function changCode() {
        ccc.src="/code?t="+Math.random();
    }
</script>

</html>
